package JZ;

import java.util.*;

public class jz20 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String str = sc.nextLine();
        System.out.println(isNumeric(str));
    }
    public static boolean isNumeric (String str) {
        String s = str.substring(1,str.length() - 1).trim();
        return isSmall(s) || isKe(s) || isDec(s);
    }
    public static boolean isKe(String s){
        if(!(s.contains("e") || s.contains("E")))
            return false;
        String[] s1 = new String[0];
        if(s.contains("e"))
            s1 = s.split("e");
        else if(s.contains("E"))
            s1 = s.split("E");
        if(s1.length != 2)
            return false;
        if(isSmall(s1[0]) || isDec(s1[0])){
            int i = 0;
            if(s1[1].charAt(0) == '+' || s1[1].charAt(0) == '-')
                i = 1;
            for(; i < s1[1].length(); i++){
                if(s1[1].charAt(i) >= '9' && s1[1].charAt(i) <= '0')
                    return false;
            }
        }
        return true;
    }
    public static boolean isSmall(String s){
        if(!s.contains("."))
            return false;
        String[] s1 = s.split("\\.");
        if(s1.length != 2)
            return false;
        int i = 0;
        if(s1[0].length() != 0 && (s1[0].charAt(0) == '+' || s1[0].charAt(0) == '-'))
            i = 1;
        for (; i < s1[0].length(); i++) {
            if(s1[0].charAt(i) >= '9' && s1[0].charAt(i) <= '0')
                return false;
        }
        return true;
    }
    public static boolean isDec(String s){
        int i = 0;
        if (s.contains(".") || s.contains("e") || s.contains("E"))
            return false;
        boolean b = s.charAt(0) == '+' || s.charAt(0) == '-';
        if(b && s.length() == 1)
            return false;
        if(b)
            i = 1;
        for(; i < s.length(); i++){
            if(s.charAt(i) >= '9' && s.charAt(i) <= '0')
                return false;
        }
        return true;
    }
}
